package com.qining618.cms.cms.controller.app.request;

import lombok.Data;

import javax.validation.constraints.Min;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.io.Serializable;

/**
 * 保存评论请求参数
 * @author flt
 * @date 2019-09-19
 */
@Data
public class AppCommentSaveRequest implements Serializable {

    private static final long serialVersionUID = 3356428566475867986L;

    @Min(value = 1, message = "上级评论不存在")
    private Long parentId;

    @Min(value = 1, message = "内容不存在")
    @NotNull(message = "内容Id不能为空")
    private Long contentId;

    @NotBlank(message = "评论内容不能为空")
    private String text;
}
